﻿<%@ Page Title="" Language="C#" MasterPageFile="~/admin/admin-site.Master" AutoEventWireup="true" CodeBehind="ManageSessions.aspx.cs" Inherits="CodeCamp12.admin.ManageSessions" %>

<asp:Content ID="Content1" ContentPlaceHolderID="cphHead" runat="server">
  <script src="../Scripts/ManageSessions.js" type="text/javascript"></script>
</asp:Content>


<asp:Content ID="Content2" ContentPlaceHolderID="cphBody" runat="server">
    <h2>Here you can create or modify sessions for all codecamp events</h2>
    
    <div id="manageSessions">
        <a href="SessionDetails.aspx" style="font-size: medium; font-weight: bold;">Add new Session</a>
        <br />
        <br/>
        <h3>Existing sessions in the database</h3>
        <label style="color: darkblue">Show sessions for: </label><select id="ddlEvents"></select>
        <br />
        <div id="SessionTemp">
        
        </div>
    </div>
    
    <script id="SessionTemplate" type="text/x-jQuery-tmpl">
            <div class="sessionDetails">
                <a href="#" class="title" name="${EventName}">${Title}</a>
                <div class="eventName">${EventName}</div>
                <br />
                by <a href="#">${Speakers}</a>
                <br />
                
                <strong>The presentation will be held in ${Language}</strong>
                <br />
                <br />
                <a href="SessionDetails.aspx?id=${ID}">Edit</a> | <a href="#" onclick="DeleteSession('${ID}');">Delete</a> <button class="btnSessionDescription">Show description</button> <button onclick="InsertImagesUrl('${ID}');" style="float:right">Add images</button>
                <br />
                    <div class="sessionDescription">
                        {{html Description}}
                    </div>
            </div>
        </script>
        
        <div id="smallDialog">
            <label>Insert the skydrive album url for this session:</label>
            <br/>
            <label class="error" style="display: none" id="lblSkyDriveLink" for="txtImageUrl">This field is required</label>
            <input type="text" id="txtImageUrl" style="width:250px;"/>
            <br/>
            <button onclick="InsertUrl();">Submit</button>
        </div>
</asp:Content>
